/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package lt.ntec.danblog.server.core.model.objectify;

import com.google.inject.Inject;
import java.util.Date;
import javax.persistence.Id;
import lt.ntec.danblog.server.core.model.User;

/**
 *
 * @author Tadas
 */
class ObjectifyUser implements User {
    private Date lastAccessDate;
    private String name;
    private String email;
    private boolean isAdmim;
    private boolean isRegistered;

    private com.google.appengine.api.users.User sysUser;

    @Id
    private Long id;


    @Inject
    public ObjectifyUser(com.google.appengine.api.users.User user) {
        this.sysUser = user;
    }

    @Override
    public void setLastAccessDate(Date date) {
        this.lastAccessDate = date;
    }

    @Override
    public Date getLastAccessDate() {
        return lastAccessDate;
    }

    @Override
    public String getName() {
       return name;
    }

    @Override
    public String getEmail() {
       return email;
    }

    @Override
    public boolean isAdmin() {
        return isAdmim;
    }

    @Override
    public boolean isRegistered() {
        return isRegistered;
    }

    @Override
    public Long getId() {
        return id;
    }

}
